import request from '@/api/request.js'

const url = '/role'
const setInterfaceUrlsUrl = url + '/setInterfaceUrls'
const getInterfaceUrlsUrl = url + '/getInterfaceUrls'
const listMenuIdUrl = url + '/listMenuId'
const listMenuGroupUrl = url + '/listMenuGroup'
export default {
  url,
  setPermissions(params) {
    return request.httpPost(setPermissionsUrl, params)
  },
  getInterfaceUrls(params) {
    return request.httpGet(getInterfaceUrlsUrl, params)
  },
  /**
   * 根据角色ID获取其绑定的菜单Ids集合
   * @param {Long} params.roleId - 角色ID
   */
  listMenuId(params) {
    return request.httpGet(listMenuIdUrl, params)
  },
}
